home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2007 September / PCWSEP07.iso / Software / Linux / Linux Mint 3.0 Light / LinuxMint-3.0-Light.iso / casper / filesystem.squashfs / usr / lib / python2.4 / lib-old / rand.pyc (.txt) < prev    next >
Encoding:
Python Compiled Bytecode  |  2007-04-29  |  588 b   |  17 lines

  1. # Source Generated with Decompyle++
  2. # File: in.pyc (Python 2.4)
  3.  
  4. import whrandom
  5.  
  6. def srand(seed):
  7.     whrandom.seed(seed % 256, seed / 256 % 256, seed / 65536 % 256)
  8.  
  9.  
  10. def rand():
  11.     return int(whrandom.random() * 32768.0) % 32768
  12.  
  13.  
  14. def choice(seq):
  15.     return seq[rand() % len(seq)]
  16.  
  17.